#!/usr/bin/python
# -*- coding: UTF-8 -*-
"""
闲云潭影日悠悠, 物转星移几度秋!
						--王勃
"""
import os, signal

def kill(pid):
	try:
		a = os.kill(pid, signal.SIGINT)
		return '已杀死pid为%s的进程,　返回值是:%s' % (pid, a)
	except OSError as e:
		return '没有此进程!!!'


if __name__ == '__main__':
	while True:
		pid = raw_input(unicode('输入要结束的进程id:', 'utf-8').encode('GBK'))
		if pid.isdigit():
			print  unicode(kill(int(pid)), 'utf-8').encode('GBK')
		else:
			print unicode('请输入数字', 'utf-8').encode('GBK')
